<?php if (!defined('THINK_PATH')) exit();?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">

<!-- Viewport Metatag -->
<meta name="viewport" content="width=device-width,initial-scale=1.0">

<!-- Plugin Stylesheets first to ease overrides -->
<link rel="stylesheet" type="text/css" href="/Public/admin/plugins/colorpicker/colorpicker.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/custom-plugins/wizard/wizard.css" media="screen">

<!-- Required Stylesheets -->
<link rel="stylesheet" type="text/css" href="/Public/admin/bootstrap/css/bootstrap.min.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/css/fonts/ptsans/stylesheet.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/css/fonts/icomoon/style.css" media="screen">

<link rel="stylesheet" type="text/css" href="/Public/admin/css/mws-style.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/css/icons/icol16.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/css/icons/icol32.css" media="screen">

<!-- Demo Stylesheet -->
<link rel="stylesheet" type="text/css" href="/Public/admin/css/demo.css" media="screen">

<!-- jQuery-UI Stylesheet -->
<link rel="stylesheet" type="text/css" href="/Public/admin/jui/css/jquery.ui.all.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/jui/jquery-ui.custom.css" media="screen">

<!-- Theme Stylesheet -->
<link rel="stylesheet" type="text/css" href="/Public/admin/css/mws-theme.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/css/themer.css" media="screen">
<link rel="stylesheet" type="text/css" href="/Public/admin/css/login.css" media="screen">
<script src="/Public/admin/js/libs/jquery-1.8.3.min.js"></script>

<link rel="stylesheet" type="text/css" href="/Public/admin/css/xcConfirm.css"/>
<script src="/Public/admin/js/jquery-1.9.1.js" type="text/javascript" charset="utf-8"></script>
<script src="/Public/admin/js/xcConfirm.js" type="text/javascript" charset="utf-8"></script>
<style type="text/css">
    .sgBtn{width: 135px; height: 35px; line-height: 35px; margin-left: 10px; margin-top: 10px; text-align: center; background-color: #0095D9; color: #FFFFFF; float: left; border-radius: 5px;}
</style>





<title>后台管理</title>

</head>

<body>


    
    <!-- Header -->
<div id="mws-header" class="clearfix" style='background:url(/Public/admin/images/head.png) no-repeat ;min-width:780px;background-size:cover;'>
    
        <!-- Logo Container -->
        <div id="mws-logo-container">
        
            <!-- Logo Wrapper, images put within this wrapper will always be vertically centered -->
           <div id="mws-logo-wrap">
                <a style='font-size:18px;color:black;'></a>
            </div>
       
        </div>
        
        <!-- User Tools (notifications, logout, profile, change password) -->
        <div id="mws-user-tools" class="clearfix">
        <div id="mws-user-message" class="mws-dropdown-menu">
            <a href="#" data-toggle="dropdown" style='font-size:20px;margin-right:10px' ><i class="icol32-arrow-rotate-clockwise" onclick='return new_redirect()' title='刷新'></i></a>
         
        </div>
         <div id="mws-user-message" class="mws-dropdown-menu">
            <a href="/index.php/home/login"  style='font-size:20px;margin-right:10px' target="_blank"><i class="icol32-drive-user" title='前台'></i></a>
        </div>
            <!-- Notifications -->
            <div id="mws-user-notif" class="mws-dropdown-menu">
               
               
            </div>
            
            <!-- Messages -->
            <div id="mws-user-message" class="mws-dropdown-menu">
               
                
                <!-- Messages dropdown -->
                <div class="mws-dropdown-box">
                    <div class="mws-dropdown-content">
      
                        <div class="mws-dropdown-viewall">
                            <a href="#">View All Messages</a>
                        </div>
                    </div>
                </div>
            </div>
            
            <!-- User Information and functions section -->
            <div id="mws-user-info" class="mws-inset">
            
                <!-- User Photo -->
                <div id="mws-user-photo" >
                    <img src="/Public/home/images/photo_1.jpg" alt="User Photo" >
                </div>
                
                <!-- Username and Functions -->
                <div id="mws-user-functions">
                    <div id="mws-username" style='color:#fff;font-size:18px;margin-right:30px;margin-left:15px'>
                        Hello, <?php echo $_SESSION['admin']['user_name']?>
                    </div>
                    <ul>                        
                        <li><a href="/index.php/Admin/login/loginout" style='font-size:13px;margin-left:15px;margin-top:23px'> 退出登录</a></li>
                    </ul>
                </div>
            </div>
           
        </div>
    </div>
    <script>
        function new_redirect(){ 
            window.location.reload();
        };

    </script>
    <!-- Start Main Wrapper -->
    <div id="mws-wrapper">
    
        <!-- Necessary markup,do not remove -->
        <div id="mws-sidebar-stitch" ></div>
        <div id="mws-sidebar-bg"style='background:#ECECEC;'></div>
        
        <!-- Sidebar Wrapper -->
        <div id="mws-sidebar" style='background:#ECECEC;'>
        
            <!-- Hidden Nav Collapse Button -->
            <div id="mws-nav-collapse">
                <span></span>
                <span></span>
                <span></span>
            </div>
            

            
            <!-- Main Navigation -->
            <div id="mws-navigation">
                <ul>
                <?php if(in_array('article',$_SESSION['node_con'])): ?><li>
                        <a href="/index.php/Admin/article/index" style='color:black'><span style='font-size:18px'><i class="icol32-page-white-paint"></i></span>&nbsp; &nbsp;信息管理</a>
                        <ul class="closed">
                            <li><a href="/index.php/Admin/article/index">系统公告列表</a></li>
                            <li><a href="/index.php/Admin/article/add">系统公告添加</a></li>
                        </ul>
                    </li><?php endif; ?>
                <?php if(in_array('role',$_SESSION['node_con'])): ?><li>
                        <a href="/index.php/Admin/role/index" style='color:black'><span style='font-size:18px'><i class="icol32-lock-break"></i></span>   &nbsp;&nbsp;权限管理</a>
                        <ul class="closed">
                            <li><a href="/index.php/Admin/role/index">管理员列表</a></li>
                            <li><a href="/index.php/Admin/role/admin_log">管理员日志</a></li>
                            <li><a href="/index.php/Admin/role/index_role">角色管理</a></li>
                        </ul>
                    </li><?php endif; ?>
                <?php if(in_array('system',$_SESSION['node_con'])): ?><li>
                        <a href="/index.php/Admin/system/set" style='color:black'><span style='font-size:18px'><i class="icol32-car"></i></span>   &nbsp;&nbsp;系统设置</a>
                        <ul class="closed">
                            <li><a href="/index.php/Admin/system/set">系统设置</a></li>
                            <li><a href="/index.php/Admin/system/param">参数管理</a></li>
                        </ul>
                    </li><?php endif; ?>
                <?php if(in_array('first',$_SESSION['node_con'])): ?><li>
                        <a href="/index.php/Admin/first/index" style='color:black'><span style='font-size:18px'><i class="icol32-directory-listing"></i></span>   &nbsp;&nbsp;首页管理</a>
                        <ul class="closed">
                            <li><a href="/index.php/Admin/first/index">广告管理</a></li>
                            <li><a href="/index.php/Admin/first/company">公司管理</a></li>
                            
                        </ul>
                    </li><?php endif; ?>
                <?php if(in_array('caiwu',$_SESSION['node_con'])): ?><li>
                        <a href="/index.php/Admin/caiwu/chongzhi" style='color:black'><span style='font-size:18px'><i class="icol32-set-security-question"></i></span> &nbsp; &nbsp;财务管理</a>
                        <ul class="closed">
                            <li><a href="/index.php/Admin/caiwu/chongzhi">充值管理</a></li>
                            <li><a href="/index.php/Admin/caiwu/zijin">资金管理</a></li>
                            <li><a href="/index.php/Admin/caiwu/shangjia">上市股权上架</a></li>
                        </ul>
                    </li><?php endif; ?>
                <?php if(in_array('user',$_SESSION['node_con'])): ?><li>
                        <a href="/index.php/Admin/user/pprg" style='color:black'><span style='font-size:18px'><i class="icol32-group"></i></span>   &nbsp;&nbsp;会员管理</a>
                        <ul class="closed">
                            <?php if(in_array('pprg',$_SESSION['node_act'])): ?><li><a href="/index.php/Admin/user/pprg">匹配认购积分</a></li><?php endif; ?>
                             <?php if(in_array('ppejf',$_SESSION['node_act'])): ?><li><a href="/index.php/Admin/user/ppejf">匹配E积分</a></li><?php endif; ?>
                             <?php if(in_array('add',$_SESSION['node_act'])): ?><li><a href="/index.php/Admin/user/add">推荐关系</a></li><?php endif; ?>
                             <?php if(in_array('organization',$_SESSION['node_act'])): ?><li><a href="/index.php/Admin/user/organization?user_name=001">组织结构</a></li><?php endif; ?>
                             <?php if(in_array('index',$_SESSION['node_act'])): ?><li><a href="/index.php/Admin/user/index">会员列表</a></li><?php endif; ?>
                            <?php if(in_array('jibie',$_SESSION['node_act'])): ?><li><a href="/index.php/Admin/user/jibie">会员级别</a></li><?php endif; ?>
                        </ul>
                    </li><?php endif; ?>
                <?php if(in_array('check',$_SESSION['node_con'])): ?><li>
                        <a href="/index.php/Admin/check/chaifen" style='color:black'><span style='font-size:18px'><i class="icol32-plugin-add"></i></span> &nbsp;&nbsp;拆分与审核</a>
                        <ul class="closed">
                            <li><a href="/index.php/Admin/check/chaifen">拆分</a></li>
                            <li><a href="/index.php/Admin/check/shenhe">审核</a></li>
                        </ul>
                    </li><?php endif; ?>
                </ul>
            </div>         
        </div>
        
        <!-- Main Container Start -->
        <div id="mws-container" class="clearfix">
            <div class="container" class="clearfix">
                <?php if($_session['success'] == true): ?><div class="mws-form-message success">
                    <ul>
                        <?php echo ($_session['success']); ?>
                    </ul>
                </div>
                <?php elseif($_session['error'] == true): ?>
                <div class="mws-form-message error">
                    <ul>
                        <?php echo ($_session['error']); ?>
                    </ul>
                </div><?php endif; ?>
                    
	<div class="mws-panel grid_8">
                	<div class="mws-panel-header">
                    	<span> 修 改 角 色 权 限</span>
                    </div>
                    <div class="mws-panel-body no-padding">
                    	<form class="mws-form" action="/index.php/Admin/role/update_role/id/<?php echo ($node['id']); ?>" method='post'>
                    		<div class="mws-form-inline">
                    			<div class="mws-form-row">
                    				<label class="mws-form-label">角 色 名 称</label>
                    				<div class="mws-form-item">
                    					<input type="text" class="small" name='role_name' value='<?php echo ($node["role"]); ?>'>
                    				</div>
                    			</div>
                    			<div class="mws-form-row">
                    				<label class="mws-form-label">角 色 描 述</label>
                    				<div class="mws-form-item">
                    					<input type="text" class="medium" name='role_desc' value='<?php echo ($node["role_desc"]); ?>'>
                    				</div>
                    			</div>
                    	
                    			<div class="mws-form-row">
                    				<label class="mws-form-label">公 告 管 理</label>
                    				<div class="mws-form-item clearfix">
                    					<ul class="mws-form-list inline">
                    						<?php if(is_array($admin_node_article)): foreach($admin_node_article as $key=>$vo): ?><li><input name='action[]' type="checkbox" <?php if(in_array($vo['id'],$role_node)): ?>checked<?php endif; ?> value='<?php echo ($vo["id"]); ?>'/> <?php echo ($vo["node_desc"]); ?>&nbsp;&nbsp;</li><?php endforeach; endif; ?>
                    					</ul>
                    				</div>
                    				<label class="mws-form-label">财 务 管 理</label>
                    				<div class="mws-form-item clearfix">
                    					<ul class="mws-form-list inline">
                    						<?php if(is_array($admin_node_caiwu)): foreach($admin_node_caiwu as $key=>$vo): ?><li><input name='action[]' type="checkbox" <?php if(in_array($vo['id'],$role_node)): ?>checked<?php endif; ?> value='<?php echo ($vo["id"]); ?>'/> <?php echo ($vo["node_desc"]); ?>&nbsp;&nbsp;</li><?php endforeach; endif; ?>
                    					</ul>
                    				</div>
                    				<label class="mws-form-label">拆 分 审 核 管 理</label>
                    				<div class="mws-form-item clearfix">
                    					<ul class="mws-form-list inline">
                    						<?php if(is_array($admin_node_check)): foreach($admin_node_check as $key=>$vo): ?><li><input name='action[]' type="checkbox" <?php if(in_array($vo['id'],$role_node)): ?>checked<?php endif; ?> value='<?php echo ($vo["id"]); ?>'/> <?php echo ($vo["node_desc"]); ?>&nbsp;&nbsp;</li><?php endforeach; endif; ?>
                    					</ul>
                    				</div>
									<label class="mws-form-label">首 页 管 理</label>
                    				<div class="mws-form-item clearfix">
                    					<ul class="mws-form-list inline">
                    						<?php if(is_array($admin_node_first)): foreach($admin_node_first as $key=>$vo): ?><li><input name='action[]' type="checkbox" <?php if(in_array($vo['id'],$role_node)): ?>checked<?php endif; ?> value='<?php echo ($vo["id"]); ?>'/> <?php echo ($vo["node_desc"]); ?>&nbsp;&nbsp;</li><?php endforeach; endif; ?>
                    					</ul>
                    				</div>
									<label class="mws-form-label">系 统 管 理</label>
                    				<div class="mws-form-item clearfix">
                    					<ul class="mws-form-list inline">
                    						<?php if(is_array($admin_node_system)): foreach($admin_node_system as $key=>$vo): ?><li><input name='action[]' type="checkbox" <?php if(in_array($vo['id'],$role_node)): ?>checked<?php endif; ?> value='<?php echo ($vo["id"]); ?>'/> <?php echo ($vo["node_desc"]); ?>&nbsp;&nbsp;</li><?php endforeach; endif; ?>
                    					</ul>
                    				</div>
									<label class="mws-form-label">会 员 管 理</label>
                    				<div class="mws-form-item clearfix">
                    					<ul class="mws-form-list inline">
                    						<?php if(is_array($admin_node_user)): foreach($admin_node_user as $key=>$vo): ?><li><input name='action[]' type="checkbox" <?php if(in_array($vo['id'],$role_node)): ?>checked<?php endif; ?> value='<?php echo ($vo["id"]); ?>'/> <?php echo ($vo["node_desc"]); ?>&nbsp;&nbsp;</li><?php endforeach; endif; ?>
                    					</ul>
                    				</div>
                    				<label class="mws-form-label">权 限 管 理</label>
                    				<div class="mws-form-item clearfix">
                    					<ul class="mws-form-list inline">
                    						<?php if(is_array($admin_node_role)): foreach($admin_node_role as $key=>$vo): ?><li><input name='action[]' type="checkbox" <?php if(in_array($vo['id'],$role_node)): ?>checked<?php endif; ?> value='<?php echo ($vo["id"]); ?>'/> <?php echo ($vo["node_desc"]); ?>&nbsp;&nbsp;</li><?php endforeach; endif; ?>
                    					</ul>
                    				</div>
                    			</div>
                    		
                    				
                    		
                    		</div>
                    		<div class="mws-button-row">
                    			<input type="submit" value=" 提 交" class="btn btn-danger">
                    			<input type="reset" value=" 重 置" class="btn ">
                    		</div>
                    	</form>
                    </div>    	
                </div>

            </div>
        </div>
            <!-- Inner Container End -->

            
            
    </div>
        <!-- Main Container End -->
        
</div>

    <!-- JavaScript Plugins -->
    
    <script src="/Public/admin/js/libs/jquery.mousewheel.min.js"></script>
    <script src="/Public/admin/js/libs/jquery.placeholder.min.js"></script>
    <script src="/Public/admin/custom-plugins/fileinput.js"></script>
    
    <!-- jQuery-UI Dependent Scripts -->
    <script src="/Public/admin/jui/js/jquery-ui-1.9.2.min.js"></script>
    <script src="/Public/admin/jui/jquery-ui.custom.min.js"></script>
    <script src="/Public/admin/jui/js/jquery.ui.touch-punch.js"></script>

    <!-- Plugin Scripts -->
    <script src="/Public/admin/plugins/datatables/jquery.dataTables.min.js"></script>
    <!--[if lt IE 9]>
    <script src="js/libs/excanvas.min.js"></script>
    <![endif]-->
     <script src="/Public/admin/plugins/flot/jquery.flot.min.js"></script>
    <script src="/Public/admin/plugins/flot/plugins/jquery.flot.tooltip.min.js"></script>
    <script src="/Public/admin/plugins/flot/plugins/jquery.flot.pie.min.js"></script>
    <script src="/Public/admin/plugins/flot/plugins/jquery.flot.stack.min.js"></script>
    <script src="/Public/admin/plugins/flot/plugins/jquery.flot.resize.min.js"></script>
    <script src="/Public/admin/plugins/colorpicker/colorpicker-min.js"></script>
    <script src="/Public/admin/plugins/validate/jquery.validate-min.js"></script>
    <script src="/Public/admin/custom-plugins/wizard/wizard.min.js"></script>

    <!-- Core Script -->
    <script src="/Public/admin/bootstrap/js/bootstrap.min.js"></script>
    <script src="/Public/admin/js/core/mws.js"></script>

    <!-- Themer Script (Remove if not needed) -->
    <script src="/Public/admin/js/core/themer.js"></script>

    <!-- Demo Scripts (remove if not needed) -->
    <script src="/Public/admin/js/demo/demo.dashboard.js"></script>
    

</body>
</html>